<%@ page language="java" contentType="text/html; charset=utf-8" pageEncoding="utf-8"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<script type="text/javascript" src="plug-in/jquery/jquery-1.8.3.min.js" /></script>
<link rel="stylesheet" href="css/index.css">
<link rel="stylesheet" href="css/shezhi.css">
<link rel="stylesheet" href="css/xiaoxi.css">
<title>隐私筛选</title>
</head>
<!--头部 -->
<%@include file="head.jsp"%>

<!--main -->

<div class="shezhi">
	<div class="shezhi_c">
		<div class="shezhi_c_top">
			<img src="imges/home.png"> > 设置 > 隐私筛选
		</div>
		<div class="shezhi_con">

			<%@include file="setLeftNaviLists.jsp"%>

			<div class="shezhi_con_r">
				<div class="shezhi_con_rtop">
					<div class="shezhi_con_rtop1" style="width: 100%">
						<ul>
							<c:if test="${options == 'privacy' }">
								<li style="width: 100px">
									<span><a href="userInfoController.do?privacyScreeningPage&options=privacy" style="color: #000">隐私设置</a></span><br> <img
										src="imges/jiayuan/jiantou.png">
								</li>
							</c:if>
							<c:if test="${options != 'privacy' }">
								<li style="width: 100px">
									<span><a href="userInfoController.do?privacyScreeningPage&options=privacy" style="color: #666">隐私设置</a></span><br>
								</li>
							</c:if>

							<c:if test="${options == 'dynamic' }">
								<li style="width: 100px">
									<span><a href="userInfoController.do?privacyScreeningPage&options=dynamic" style="color: #000">动态发布设置</a></span><br> <img
										src="imges/jiayuan/jiantou.png">
								</li>
							</c:if>
							<c:if test="${options != 'dynamic' }">
								<li style="width: 100px">
									<span><a href="userInfoController.do?privacyScreeningPage&options=dynamic" style="color: #666">动态发布设置</a></span><br>
								</li>
							</c:if>

							<c:if test="${options == 'Filtrate' }">
								<li style="width: 100px">
									<span><a href="userInfoController.do?privacyScreeningPage&options=Filtrate" style="color: #000">动态筛选</a></span><br> <img
										src="imges/jiayuan/jiantou.png">
								</li>
							</c:if>
							<c:if test="${options != 'Filtrate' }">
								<li style="width: 100px">
									<span><a href="userInfoController.do?privacyScreeningPage&options=Filtrate" style="color: #666">动态筛选</a></span><br>
								</li>
							</c:if>

						</ul>
					</div>
				</div>

				<c:if test="${options == 'privacy' }">
					<from id="privacy">
					<div class="shezhi_con_rc">
						<div class="fwtg" style="line-height: 40px; height: 40ox;">
							<span>您可以完全控制哪些人可以看到您的主页上面的内容</span><br>
						</div>
					</div>
					<div class="shezhi_con_rc" style="margin-top: 10px">
						<div class="geren_ys">好友列表 :</div>
						<div class="geren_ys1">
							<select class="geren_ys1_sel"  name="hyValue" id="hyValue" >
								<option value="0">公开</option>
								<option value="1">好友可见</option>
								<option value="2">保密</option>
								<option value="3">仅注册用户可见</option>
							</select>
						</div>
					</div>

					<div class="shezhi_con_rc">
						<div class="geren_ys">留言板 :</div>
						<div class="geren_ys1">
							<select class="geren_ys1_sel" name="lybValue" id="lybValue" >
								<option value="0">公开</option>
								<option value="1">好友可见</option>
								<option value="2">保密</option>
								<option value="3">仅注册用户可见</option>
							</select>
						</div>
					</div>

					<div class="shezhi_con_rc">
						<div class="geren_ys">动态 :</div>
						<div class="geren_ys1">
							<select class="geren_ys1_sel" name="dtValue" id="dtValue">
								<option value="0">公开</option>
								<option value="1">好友可见</option>
								<option value="3">仅注册用户可见</option>
							</select>
						</div>
					</div>

					<div class="shezhi_con_rc">
						<div class="geren_ys">记录 :</div>
						<div class="geren_ys1">
							<select class="geren_ys1_sel" name="jlValue" id="jlValue">
								<option value="0">公开</option>
								<option value="1">好友可见</option>
								<option value="3">仅注册用户可见</option>
							</select>
							<br>
						</div>
						<div class="geren_ys2">
							<span style="color: #d9d9d9">本隐私设置仅在其他用户查看您主页时有效，在全站记录列表中可能会出现您的记录</span>
						</div>
					</div>

					<div class="shezhi_con_rc">
						<div class="geren_ys" style="margin-top: 15px">日志 :</div>
						<div class="geren_ys1">
							<select class="geren_ys1_sel" name="rzValue" id="rzValue">
								<option value="0">公开</option>
								<option value="1">好友可见</option>
								<option value="3">仅注册用户可见</option>
							</select>
							<br>
						</div>
						<div class="geren_ys2">
							<span style="color: #d9d9d9">本隐私设置仅在其他用户查看您主页时有效，相关浏览权限需要在发表时单独设置方完全生效</span>
						</div>
					</div>

					<div class="shezhi_con_rc">
						<div class="geren_ys"style="margin-top: 15px">相册 :</div>
						<div class="geren_ys1" >
							<select class="geren_ys1_sel" name="xcValue" id="xcValue">
								<option value="0">公开</option>
								<option value="1">好友可见</option>
								<option value="3">仅注册用户可见</option>
							</select>
							<br>
						</div>
						<div class="geren_ys2">
							<span style="color: #d9d9d9">本隐私设置仅在其他用户查看您主页时有效，相关浏览权限需要在发表时单独设置方完全生效</span>
						</div>
					</div>

					<div class="shezhi_con_rc">
						<div class="geren_ys" style="margin-top: 15px">分享 :</div>
						<div class="geren_ys1">
							<select class="geren_ys1_sel" name="fxValue" id="fxValue">
								<option value="0">公开</option>
								<option value="1">好友可见</option>
								<option value="3">仅注册用户可见</option>
							</select>
							<br>
						</div>
						<div class="geren_ys2">
							<span style="color: #d9d9d9">本隐私设置仅在其他用户查看您主页时有效，相关浏览权限需要在发表时单独设置方完全生效</span>
						</div>
					</div>

					<div class="shezhi_con_rc3">
						<span><button class="shezhi_con_rc3_button" id="but_save" onclick="savePrivacy('privacy')" >保存</button></span>
					</div>

					</from>
				</c:if>

				<c:if test="${options == 'dynamic' }">
					<from id="dynamic">
					<div class="shezhi_con_rc">
						<div class="fwtg" style="font-size: 13px">
							<span>系统会将您的各项动作反映到个人动态里，方便朋友 了解您的动态</span><br> <span>您可以控制是否在下列动作发生时，在个人动态里发布相关信息</span>
						</div>
					</div>

					<div class="dongtai_sx">
						<ul>
							<li>
								<c:if test="${userDynamicSet.record == '1'}">
									<input type="checkbox" id="jl" name="info" checked="checked">
								</c:if>
								<c:if test="${userDynamicSet.record == '0'}">
									<input type="checkbox" id="jl" name="info">
								</c:if>
								<label>记录</label>
							</li>
							
							<li>
								<c:if test="${userDynamicSet.log == '1'}">
									<input type="checkbox" id="rz" name="info" checked="checked">
								</c:if>
								<c:if test="${userDynamicSet.log == '0'}">
									<input type="checkbox" id="rz" name="info">
								</c:if>
								撰写日志
							</li>
							
							<li>
								<c:if test="${userDynamicSet.uploadImg == '1'}">
									<input type="checkbox" id="img" name="info" checked="checked">
								</c:if>
								<c:if test="${userDynamicSet.uploadImg == '0'}">
									<input type="checkbox" id="img" name="info">
								</c:if>
								上传图片
							</li>
							<li>
								<c:if test="${userDynamicSet.addShare == '1'}">
									<input type="checkbox" id="fx" name="info" checked="checked">
								</c:if>
								<c:if test="${userDynamicSet.addShare == '0'}">
									<input type="checkbox" id="fx" name="info">
								</c:if>
								添加分享
							</li>
							
							<li>
								<c:if test="${userDynamicSet.addFirend == '1'}">
									<input type="checkbox" id="hy" name="info" checked="checked">
								</c:if>
								<c:if test="${userDynamicSet.addFirend == '0'}">
									<input type="checkbox" id="hy" name="info">
								</c:if>
								添加好友
							</li>
							<li>
								<c:if test="${userDynamicSet.comment == '1'}">
									<input type="checkbox" id="pl" name="info" checked="checked">
								</c:if>
								<c:if test="${userDynamicSet.comment == '0'}">
									<input type="checkbox" id="pl" name="info">
								</c:if>
								发表评论/留言
							</li>

							<li>
								<c:if test="${userDynamicSet.paidListing == '1'}">
									<input type="checkbox" id="jjpm" name="info" checked="checked">
								</c:if>
								<c:if test="${userDynamicSet.paidListing == '0'}">
									<input type="checkbox" id="jjpm" name="info">
								</c:if>
								竞价排名
							</li>
							<li>
								<c:if test="${userDynamicSet.pointConsumption == '1'}">
									<input type="checkbox" id="jfxf" name="info" checked="checked">
								</c:if>
								<c:if test="${userDynamicSet.pointConsumption == '0'}">
									<input type="checkbox" id="jfxf" name="info">
								</c:if>
								积分消费
							</li>
							<li>
								<c:if test="${userDynamicSet.inviteFriends == '1'}">
									<input type="checkbox" id="yqhy" name="info" checked="checked">
								</c:if>
								<c:if test="${userDynamicSet.inviteFriends == '0'}">
									<input type="checkbox" id="yqhy" name="info">
								</c:if>
								邀请好友
							</li>
							<li>
								<c:if test="${userDynamicSet.completionTask == '1'}">
									<input type="checkbox" id="wcrw" name="info" checked="checked">
								</c:if>
								<c:if test="${userDynamicSet.completionTask == '0'}">
									<input type="checkbox" id="wcrw" name="info">
								</c:if>
								完成任务
							</li>
							<li>
								<c:if test="${userDynamicSet.updateInfor == '1'}">
									<input type="checkbox" id="grzl" name="info" checked="checked">
								</c:if>
								<c:if test="${userDynamicSet.updateInfor == '0'}">
									<input type="checkbox" id="grzl" name="info">
								</c:if>
								更新个人资料
							</li>
							<li>
								<c:if test="${userDynamicSet.rzDeclare == '1'}">
									<input type="checkbox" id="bt" name="info" checked="checked"">
								</c:if>
								<c:if test="${userDynamicSet.rzDeclare == '0'}">
									<input type="checkbox" id="bt" name="info">
								</c:if>
								对日志/图片表态
							</li>
							<li>
								<c:if test="${userDynamicSet.forumFt == '1'}">
									<input type="checkbox" id="rtft" name="info" checked="checked">
								</c:if>
								<c:if test="${userDynamicSet.forumFt == '0'}">
									<input type="checkbox" id="rtft" name="info">
								</c:if>
								论坛发帖
							</li>
							<li>
								<c:if test="${userDynamicSet.forumHt == '1'}">
									<input type="checkbox"  id="rtht" name="info" checked="checked">
								</c:if>
								<c:if test="${userDynamicSet.forumHt == '0'}">
									<input type="checkbox" id="rtht" name="info">
								</c:if>
								论坛回帖
							</li>
						</ul>
					</div>
					<div style="width: 38%; margin: 0 auto;">
						<span><button class="shezhi_con_rc3_button" id="but_save" onclick="savePrivacy('dynamic')" >保存</button></span>
					</div>
					</from>
				</c:if>

				<c:if test="${options == 'Filtrate' }">
					<from id="Filtrate">
					<div class="shezhi_con_rc">
						<div class="fwtg" style="font-size: 13px">
							<span style="color: #000">筛选规则一：屏蔽指定用户组的动态</span><br> <span>筛选规则一：屏蔽指定用户组的动态，屏蔽用户组内的组员所发布的动态都将屏蔽掉（仅限查看好友的动态时生效）</span>
						</div>
					</div>

					<div class="dongtai_sx">
						<ul>
							<li>
								<c:if test="${shieldingEntity.other == '1'}">
									<input type="checkbox" id="qt" value="0"  checked="checked">
								</c:if>
								<c:if test="${shieldingEntity.other == '0'}">
									<input type="checkbox" id="qt" value="0">
								</c:if>	
								<label>其他</label>
							</li>
							<li>
								<c:if test="${shieldingEntity.site == '1'}">
									<input type="checkbox" id="bzrs" value="0"  checked="checked">
								</c:if>
								<c:if test="${shieldingEntity.site == '0'}">
									<input type="checkbox" id="bzrs" value="0">
								</c:if>	
								通过本站认识
							</li>
							<li>
								<c:if test="${shieldingEntity.activity == '1'}">
									<input type="checkbox" id="hdrs" value="0"  checked="checked">
								</c:if>
								<c:if test="${shieldingEntity.activity == '0'}">
									<input type="checkbox" id="hdrs" value="0">
								</c:if>	
								通过活动认识
							</li>
							<li>
								<c:if test="${shieldingEntity.firend == '1'}">
									<input type="checkbox" id="pyrs" value="0"  checked="checked">
								</c:if>
								<c:if test="${shieldingEntity.firend == '0'}">
									<input type="checkbox" id="pyrs" value="0">
								</c:if>	
								通过朋友认识
							</li>
							<li>
								<c:if test="${shieldingEntity.family == '1'}">
									<input type="checkbox" id="qr" value="0"  checked="checked">
								</c:if>
								<c:if test="${shieldingEntity.family == '0'}">
									<input type="checkbox" id="qr" value="0">
								</c:if>	
								亲人
							</li>
							<li>
								<c:if test="${shieldingEntity.colleagues == '1'}">
									<input type="checkbox" id="ts" value="0"  checked="checked">
								</c:if>
								<c:if test="${shieldingEntity.colleagues == '0'}">
									<input type="checkbox" id="ts" value="0">
								</c:if>	
								同事
							</li>
							<li>
								<c:if test="${shieldingEntity.classmates == '1'}">
									<input type="checkbox" id="tx" value="0"  checked="checked">
								</c:if>
								<c:if test="${shieldingEntity.classmates == '0'}">
									<input type="checkbox" id="tx" value="0">
								</c:if>	
								同学
							</li>
							<li>
								<c:if test="${shieldingEntity.noKnow == '1'}">
									<input type="checkbox" id="brs" value="0"  checked="checked">
								</c:if>
								<c:if test="${shieldingEntity.noKnow == '0'}">
									<input type="checkbox" id="brs" value="0">
								</c:if>	
								不认识
							</li>
							<li></li>
						</ul>
					</div>
					<div style="width: 38%; margin: 0 auto;">
						<span><button class="shezhi_con_rc3_button" id="but_save" onclick="saveFiltrate()" >保存</button></span>
					</div>
					<div class="dongtai_sx1">
						<span>您可以在自己的<span style="color: #0090ee"> 好友列表 </span> 中，对好友进行分组，并可以对用户组进行改名
						</span>
					</div>

					<div class="shezhi_con_rc" style="border-top: 1px dashed #f1f1f1; margin-top: 20px; border-bottom: 1px dashed #f1f1f1">
						<div class="fwtg" style="font-size: 13px; height: auto; border-bottom: none">
							<span style="color: #000">筛选规则二:屏蔽指定好友指定类型的动态</span><br> <span style="display: inline-block; margin-top: 10px">点击一下首页好友动态列表后面的屏蔽标志，就可以屏蔽指定好友指定类型的动态了。</span><br>
							<span>下面列出的是您可以屏蔽的动态类型识别名和好友名，您可以选择是否取消屏蔽</span><br>
						</div>
						<div style="width: 45%; height: 70px; line-height: 70px; margin: 0 auto">
							<span>现在还没有屏蔽的动态类型</span>
						</div>
					</div>

					<div class="shezhi_con_rc" style="border-bottom: 1px dashed #f1f1f1">
						<div class="fwtg" style="font-size: 13px; height: auto; border-bottom: none">
							<span style="color: #000">筛选规则二:屏蔽指定好友指定类型的动态</span><br> <span style="display: inline-block; margin-top: 10px">点击一下首页好友动态列表后面的屏蔽标志，就可以屏蔽指定好友指定类型的动态了。</span><br>
							<span>下面列出的是您可以屏蔽的动态类型识别名和好友名，您可以选择是否取消屏蔽</span><br>
						</div>
						<div style="width: 45%; height: 70px; line-height: 70px; margin: 0 auto">
							<span>现在还没有屏蔽的动态类型</span>
						</div>
					</div>
					</from>
				</c:if>
			</div>
			<div style="clear: both"></div>
		</div>
		<div style="clear: both"></div>
	</div>
</div>

<!--foot -->
<%@include file="foot.jsp"%>

</body>
<script type="text/javascript" src="js/saveprivacyset.js"></script>
</html>
<script type="text/javascript" >
//以下各选项的设置
var selecthyValue = document.getElementById("hyValue");  //好友
var selectlybValue = document.getElementById("lybValue");  //留言
var selectdtValue = document.getElementById("dtValue");  //动态
var selectjlValue = document.getElementById("jlValue");  //记录
var selectrzValue = document.getElementById("rzValue");	//日志
var selectxcValue = document.getElementById("xcValue");	//相册
var selectfxValue = document.getElementById("fxValue");	//分享
 
var friendList = ${userPrivacySet.friendList};  
var messageBoard = ${userPrivacySet.messageBoard}; 
var dynamicState = ${userPrivacySet.dynamicState}; 
var record = ${userPrivacySet.record}; 
var log = ${userPrivacySet.log};  
var photoAlbum = ${userPrivacySet.photoAlbum}; 
var share = ${userPrivacySet.share}; 

for(var i=0; i<selecthyValue.options.length; i++){  
    if(selecthyValue.options[i].value == friendList){  
        selecthyValue.options[i].selected = true;  
        break;  
    }  
}  

 
for(var i=0; i<selectlybValue.options.length; i++){  
    if(selectlybValue.options[i].value == messageBoard){  
        selectlybValue.options[i].selected = true;  
        break;  
    }  
} 


for(var i=0; i<selectdtValue.options.length; i++){  
    if(selectdtValue.options[i].value == dynamicState){  
        selectdtValue.options[i].selected = true;  
        break;  
    }  
} 


for(var i=0; i<selectjlValue.options.length; i++){  
    if(selectjlValue.options[i].value == record){  
        selectjlValue.options[i].selected = true;  
        break;  
    }  
} 


for(var i=0; i<selectrzValue.options.length; i++){  
    if(selectrzValue.options[i].value == log){  
        selectrzValue.options[i].selected = true;  
        break;  
    }  
} 


for(var i=0; i<selectxcValue.options.length; i++){  
    if(selectxcValue.options[i].value == photoAlbum){  
        selectxcValue.options[i].selected = true;  
        break;  
    }  
} 


for(var i=0; i<selectfxValue.options.length; i++){  
    if(selectfxValue.options[i].value == share){  
        selectfxValue.options[i].selected = true;  
        break;  
    }  
} 




</script>
